<template>
<div>
    <Table :columns="columns1" :data="data1"></Table>
</div>
</template>

<script>
import { selectConcentratedObservationList } from '@/api/outbreak-management/dataStatistics'
export default {
  name: 'index',
  data () {
    return {
      // 列
      columns1: [
        {
          title: '日期',
          key: 'imp_date'
        },
        {
          title: '姓名',
          key: 'name'
        },
        {
          title: '性别',
          key: 'sex'
        },
        {
          title: '年龄',
          key: 'age'
        },
        {
          title: '证件类型',
          key: 'card_type'
        },
        {
          title: '证件号',
          key: 'card_no'
        },
        {
          title: '联系电话',
          key: 'tel'
        },
        {
          title: '隔离开始时间',
          key: 'start_time'
        },
        {
          title: '隔离结束时间',
          key: 'end_time'
        },
        {
          title: '来源地类型',
          key: 'source_type'
        },
        {
          title: '来源地',
          key: 'source'
        },
        {
          title: '隔离宾馆',
          key: 'isolation_hotel'
        }
      ],
      // 表格
      data1: []
    }
  },
  methods: {
    getDataStatistics () {
      console.log('ret')
      selectConcentratedObservationList().then(ret => {
        console.log('ret222')
        console.log(ret.data, 'ret.data')
        let data = ret.data
        if (data.errcode === 0) {
          console.log(data.data, 'data.data')
          this.data1 = data.data
        } else {
          this.error(data)
        }
      })
    }
  },
  mounted () {
    console.log('aasdasd')
    this.getDataStatistics()
  }
}
</script>

<style scoped>

</style>
